package com.katze.common.http;

import org.springframework.web.bind.annotation.RequestMethod;

import java.io.IOException;
import java.io.InputStream;
import java.net.HttpURLConnection;
import java.util.function.BiConsumer;
import java.util.function.Consumer;

public interface SendRequest {

    default String sendRequest(RequestMethod method) throws IOException {
        return null;
    }

    default void sendRequest(Consumer<InputStream> consumer, RequestMethod method) throws IOException {}

    default void sendRequest(BiConsumer<HttpURLConnection, InputStream> consumer, RequestMethod method) throws IOException {}
}
